{% extends 'public/base.html' %}
{% load filter_tool %}


{% block style %}

  <link href="{{ STATIC_URL }}css/ask.css?{% now "U" %}" rel="stylesheet" type="text/css" media="screen" />


{% endblock %}


{% block content %}

{% include 'public/icollege_nav.html' %} 

  <div class="fl" >
  	   <div class="ask" style="font-size:12px" >
          {% for q in questions %}
               <div class="question" >
                  <div style="" >
                    {% if q.q.anonymity %}

                    {% else %}

                        {% if q.u.url %}
                           <a class="uh"  href="/people/{{ q.u.url }}">
                          <img title="{{ q.u.nickname }}" src="{{ avatar_url }}{{ q.u.head }}">
                        </a>
                        {% else %}

                         <a class="uh"  href="/people/{{ q.u.id }}">
                          <img title="{{ q.u.nickname }}" src="{{ avatar_url }}{{ q.u.head }}">
                        </a>

                        {% endif %}

                     {% endif %}
                   
                    <h2><a href="/question/{{ q.q.id }}" >{{ q.q.question }}</a><a href=""></a></h2>
                  </div>
                  
                  <div class="q_state" >
                        <h3>
                           {% if q.t %}
                           <span>
                               标签:
                               {% for s in q.t %}
                                  <a href="#" >{{ s.tag }}</a>
                               {% endfor %}
                            </span>
                           {% endif %}
                            {% if q.s %}
                           <span>
                               主题:
                               {% for s in q.s %}
                                  <a href="/ask/subject/{{ s.id }}/{{ s.subject }}" >{{ s.subject }}</a>
                               {% endfor %}
                            </span>
                           {% endif %}
                      </h3>
                      <span>{{ q.q.answer_count }}个答案</span>
                      <span style="margin-left: 15px;float:right;padding-top:2px" >{{ q.q.create_time|date:'Y-m-d  H:i' }}</span>
                  </div>
              </div>
          {% endfor %}
      </div>
  </div>
  <div class="fr" >
      <div class="wrap_subject" >
        <h3>focus的所有主题</h3>
          <div class="sj" style="padding-top:10px" >
            <ul>
              {% for s in subjects %}
                <li  ><a   class="subject" id="{{ s.id }}" href="/ask/subject/{{ s.id }}/{{ s.subject }}">{{ s.subject }}({{ s.question_count }})</a></li>
              {% endfor %}
            </ul>
          </div>
      </div>
  </div>
  <div class="page" >
      {% if page.prev_page_number%}
     <a href="/i/college/ask?page={{ page.prev_page_number }}" class="prev"> <<-上一页</a>
     {% endif %}
      
     {% if page.has_next   %}
         <a href="/i/college/ask?page={{ page.next_page_number }}" class="next" >下一页->></a>
     {% endif %}
  </div>

{% endblock %}